<template>
  <div id="app">
    <div v-if="false" class="top_wrap">
      <router-link to="/home">首页</router-link>
      <router-link to="/search">搜索</router-link>
      <router-link to="/find">发现音乐</router-link>
      <router-link to="/my">我的音乐</router-link>
      <router-link to="/friend">朋友</router-link>
    </div>
    <div class="content">
      <!-- 必须为组件配置名称 name，否则会不管用哦 -->
      <keep-alive :include="['LayOut']">
        <router-view></router-view>
      </keep-alive>
    </div>
  </div>
</template>

<script>
export default {
  name: "App",
  components: {},
  data() {
    return {
      
    };
  },
};
</script>

<style>
body {
  margin: 0;
  padding: 0;
}
#app {
  font-family: Avenir, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-align: center;
  color: #2c3e50;
  margin-top: 60px;
}
.top_wrap {
  position: fixed;
  left: 0;
  top: 0;
  display: flex;
  width: 100%;
  text-align: center;
  background-color: #333;
  color: white;
}
.top_wrap a {
  flex: 1;
  text-decoration: none;
  padding: 20px 0;
  line-height: 20px;
  font-size: 14px;
  color: #fff;
  border: 1px solid black;
}
/* 模糊匹配高亮，用的比较多，对于多级路由时 */
.top_wrap a.active {
  background-color: darkgoldenrod;
}
.top_wrap a:hover {
  box-shadow: inset 0 0 10px 0px white;
}
</style>
